package com.hk.jmm.app;

import android.app.Activity;
import android.content.Intent;
import android.graphics.Color;
import android.os.Bundle;
import android.view.View;

import androidx.annotation.NonNull;

import com.hk.jmm.R;
import com.hk.jmm.model.LRModel;
import com.hk.jmm.presenter.LRPresenter;
import com.skyz.base.activity.BaseMvpActivity;

import java.util.List;

public class LoginAndRegisterActivity extends BaseMvpActivity<LRModel, LoginAndRegisterActivity, LRPresenter> {
    public static void showActivity(Activity activity) {
        Intent intent = new Intent(activity, LoginAndRegisterActivity.class);
        activity.startActivity(intent);
    }

    @Override
    protected void onMessageEvent(Object event) {

    }


    @Override
    protected int getLayoutId() {
        return R.layout.activity_login_register;
    }


   



    @Override
    protected void onLayoutInflated() {
        setStatusBarBackgroundColor(Color.WHITE);


    }

    @Override
    protected void initData(Bundle savedInstanceState) {
        findViewById(R.id.click_login).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
//               LoginActivity.showActivity(LoginAndRegisterActivity.this);
                MainActivity.showActivity(LoginAndRegisterActivity.this);
            }
        });
        findViewById(R.id.click_register).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                RegisterActivity.showActivity(LoginAndRegisterActivity.this);
            }
        });
    }




    @Override
    protected LRPresenter initMvpPresenter() {
        return new LRPresenter(this, getLifecycle());
    }
}
